#ifndef DECLARATIONS_HPP
#define DECLARATIONS_HPP

#include <fstream>
#include <iostream>
#include <map>
#include <string>
#include <vector>
using namespace std;

#include <pcrecpp.h>
using namespace pcrecpp;

#include <boost/algorithm/string.hpp>
#include <boost/regex.hpp>
using namespace boost;

#ifndef TYPICAL_STRINGS
#define TYPICAL_STRINGS
// Some oft-used strings.
static const string blank( "" );
#endif
static const string date = "[0-9]{4}-[0-9]{2}-[0-9]{2}";

#ifndef PCRE_ICASE
#define PCRE_ICASE
// SQL being case-insensitive,
// our patterns must be too.
static const RE_Options icase( PCRE_CASELESS );
#endif

// Some convenient custom typenames.
typedef vector<string> strings;
typedef pair<string,string> two_strings;

typedef pair<string,unsigned> string_count_pair;
typedef pair< string, pair< two_strings, string > > qualified_identity;
typedef pair<qualified_identity,unsigned> qi_count_pair;
typedef map<qualified_identity,unsigned> qi_count_map;

qualified_identity make_triplet( const string& s1,
		const two_strings& s2, const string& s3){
	return make_pair( s1, make_pair( s2, s3 ) );
}

#endif
